const Jszip = require('jszip');

const zip = new Jszip();

const folder1 = zip.folder('folder1');
folder1.file('1.json', '{"a": 1}');
folder1.folder();
zip.generateAsync({ type: 'blob' }).then((content) => {
  console.log(content);
});
